@import "../../../assets/css/global";

#detail {

  .wxParse-p{
    image {
      width: 100% !important;
    }
  }

  .top-tap {
    display: flex;
    align-content: center;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 20;
    padding: 6px 10%;
    font-size: 14px;
    background: #FFFFFF;
    color: #4A4A4A;
    box-sizing: border-box;
    .item{
      flex: 1;
      text-align: center;

      .name {
        display: inline-block;
        padding: 5px 0;
        &.active {
          color: @globalColor;
          border-bottom: 2px solid @globalColor;
        }
      }

    }

    .share {

      position: relative;
      right: -10px;
      background: #FFFFFF;
      border-radius: 0;
      margin: 0;
      padding: 0;
      top: 4px;
      line-height: inherit;
      font-size: 16px;
      &:after {
        border: none;
      }
    }
  }
  .top-box {
    padding-top: 40px;
    swiper {
      height: 730rpx;
      background: #ffffff;

      .slide-image {
        width: 100%;
        height: 100%;
      }
    }
    .basic-information {
      font-size: 12px;
      background: #ffffff;
      .goods-name {
        font-size:14px;
        color:#000000;
        padding:5px 15px;
      }
      .goods-price {
        display: flex;
        padding:0 15px;
        align-items: center;
        color:#ee2b1d;
        .price {
          font-size:20px;
          color: @globalColor;
          margin-right: 5px;
        }
      }
      .market-price-box {
        display:flex;
        align-items:center;
        justify-content:space-between;
        padding:0 15px 10px 15px;
        font-size:12px;
        color:#959595;
        .market-price {
          text-decoration:line-through;

        }
      }
      .tags-box {
        padding:0 15px 10px 15px;
        span{
          font-size:10px;
          color:#9f9f9f;
          background:#e4e4e4;
          border-radius:4px;
          padding:3px 5px;
          margin-right:5px;
          margin-top:5px;
          display:inline-block;

        }
      }
      .coupons-tags {
        padding: 10px 15px;
        display: flex;
        align-items: baseline;

        .tags-title {
          width: 30px;
          color: #585757;
          font-weight: bold;
        }
        .coupon-box {
          display: flex;
          flex-wrap: wrap;
          flex-direction: row;
          justify-content: flex-start;
          align-items: center;
          flex: 1;
          .tags-item {
            color: #ffffff;
            background: @globalColor;
            padding: 2px 7px;
            position: relative;
            margin: 5px 10px 5px 0;
            .dot-wrap {

              .dot-left {
                position: absolute;
                top: 0;
                left: 5px;
              }
              .dot-right {
                position: absolute;
                top: 0;
                right: -4px;
              }
              .dot-item {
                width: 5px;
                height: 5px;
                background: #F7F7F7;
                border-radius: 50%;
                margin: 2px 0 2px -7px;

                &:last-child {
                  margin-top: 0;
                }
              }
            }
          }
        }

      }
      .discounts-tags {
        display: flex;
        padding: 10px 15px;
        align-items: baseline;
        .tags-title {
          width: 30px;
          color: #585757;
          font-weight: bold;
        }
        .discounts-box {
          flex: 1;
          overflow: hidden;
          .disconts-item {
            display: flex;
            align-items: center;
            margin-bottom: 10px;

            &:last-child {
              margin-bottom: 0;
            }
            .discounts-tags-title {
              color: @globalColor;
              border: 1px solid @globalColor;
              border-radius: 3px;
              padding: 0 5px;
              margin-right: 10px;
            }
            .tags-item{
              white-space: nowrap;
              overflow: hidden;
              text-overflow: ellipsis;
              flex: 1;
            }
          }
        }
      }
    }
  }
  .wrap-item {

    background-color:#FFFFFF;
    margin-top:10px;

    &.commodity {
      padding-bottom: 80px;
    }
    .title {
      display:flex;
      padding:10px 15px;
      align-items: center;
      font-size:14px;
      .text {
        flex: 1;
      }
      .arrow-up {
        width: 30px;
        height: 10px;
        margin-top: 3px;
        background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/down.png") no-repeat center;
        transform: rotate(180deg);
        background-size: 10px;
      }
      .arrow-down {
        width: 20px;
        height: 10px;
        background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/down.png") no-repeat center;
        background-size: 10px;
        margin-right: 5px;
      }
    }
    .content {
      padding:10px 15px;
      box-sizing:border-box;

      //商品评论
      .comment_list {
        font-size: 12px;
        line-height: 20px;

        .comment_user {
          display: flex;
          align-items: center;
          .img-box {
            display: flex;
            align-items: center;
            flex: 1;
            image{
              width: 25px;
              height: 25px;
              border-radius: 100%;
            }
          }
          .rater {
            .vlc-rater {
              display: flex;
            }
          }
          .user_name {
            margin-left: 15px;
            display: inline-block;
            color: #717071;
          }
        }

        .comment_content {
          margin-top: 0px;
        }

        .comment-img {
          font-size: 0;
          margin: 5px 0;
          image{
            display: inline-block;
            width: 25%;
            //height: 100%;
            padding: 0 5px;
          }
        }

        .comment_time {
          display: flex;
          align-items: center;
          margin: 10px 0;
          .time {
            margin-right: 15px;
          }
          color: #838282;
        }
        .all-comment {
          text-align: center;
          .text {
            margin-top: 10px;
            display: inline-block;
            font-size: 10px;
            color: #4A4A4A;
            border: 1px solid #4A4A4A;
            border-radius: 3px;
            padding: 2px 4px;
          }
        }
      }

      //商品参数
      .argument-box {
        color: #000000;

        .argument-top {
          line-height: 20px;

          span {
            display: inline-block;
            font-size: 10px;
            width: 50%;
            box-sizing: border-box;
            background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/goods-list.png") no-repeat left;
            padding-left: 15px;
          }
        }
        .argument-bottom {
          font-size: 10px;
          margin-top: 35px;

          .argument-item {
            display: flex;
            margin-bottom: 10px;

            .index-box {
              flex: 1;
              ul {
                display: flex;
                background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/lvl-bg.png") repeat-x top;

                .red-dot {
                  background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/red-dot.png") no-repeat top;
                }
                li {
                  flex: 1;
                  display: inline-block;
                  text-align: center;
                  padding-top: 15px;
                  background: url("https://ibrand-miniprogram.oss-cn-hangzhou.aliyuncs.com/小程序/dot.png") no-repeat top;
                }
              }
            }
          }
        }
      }
    }
  }
  .tabbar {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 55px;
    z-index: 50;
    color: #9B9B9B;
    font-size: 13px;
    background: #FFFFFF;
    display: flex;

    .tabbar-item {
      display: flex;
      flex: 1;
      width: 0%;
      justify-content: center;
      align-items: center;
      font-size: 12px;
      flex-direction: column;
      i{
        font-size: 20px;
      }
      &.show-cart {
        color: #ffffff;
        background: #000;
        font-size:18px;
        font-weight:bold;
        flex: 2;

        &.active {
          background: @globalColor;
        }
        &.disabled {
          background: #C2C2C2;
        }
      }
      &.favorite{
        color: @globalColor;
        i{
          color: @globalColor;
        }
      }
    }
  }


  .maks{
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 100%;
    z-index: 40;
    background: rgba(0,0,0,.4);
    opacity: 1;
    transition: opacity .3s ease;
    display: none;

    &.cur{
      display: block;
    }
  }
  .sku-popup {
    width:100%;
    position:fixed;
    left:0;
    bottom:-55px;
    z-index:51;
    transform:translate3d(0, 100, 0);

    .select-goods-cloese {

      position: absolute;
      top:12px;
      right:10px;
      width:20px;
      height:20px;
      background: transparent;
      z-index:4;
      overflow:visible;

      &:before{
        position: absolute;
        top:9px;
        left:-1px;
        content: '';
        width:28px;
        height:2px;
        background: #2e2e2e;
        transform: rotate(45deg) ;


      }
      &:after{
        top:9px;
        left:-1px;
        position: absolute;
        content: '';
        width:28px;
        height:2px;
        background: #2e2e2e;
        transform: rotate(-45deg);


      }
    }

    .select-goods-container {
      background:#ffffff;
      position:relative;
      z-index:100;
      .select-goods-header {
        position: relative;
        height: 60px;
        .img-box {
          position: absolute;
          left: 10px;
          bottom: 10px;
          width: 78px;
          height: 78px;
          border: 1px solid #e5e5e5;
          background: #f9f9f9;
          image {
            width: 100%;
            height: 100%;
          }
        }
        .price-box {
          font-size: 18px;
          margin-left: 100px;
          height: 100%;
          display: flex;
          flex-direction: column;
          justify-content: center;
          .price {
            font-weight: bold;
            color: #ee2b1d;
          }
          .count {
            font-size: 14px;
            color: #6c6c6c;
            text-indent: 3px;
          }
        }
      }
      .select-goods-spec {
        font-size:12px;
        padding:12px 8px 50px 8px;

        .spec-line {
          display:flex;
          margin-bottom:15px;
          .spec-title {
            padding-right:11px;
            color:#c4c4c4;
            width:50px;
            line-height:35px;
          }
          .spec-value {
            flex:1;
            font-size:0;
            margin-top:-10px;

            .spec-block {
              display:inline-block;
              margin-top:10px;
              margin-right:10px;

              .spec-text {
                display: block;
                padding: 0 7px;
                height: 33px;
                line-height: 33px;
                min-width: 20px;
                border: 1px solid #DDDDDD;
                text-align: center;
                font-size: 12px;
                position: relative;
              }

              &.active span {
                &:before {
                  content: '';
                  position: absolute;
                  border: 3px solid @globalColor;
                  top: -1px;
                  left: -1px;
                  right: -1px;
                  bottom: -1px;
                }
              }

              &.disabled span {
                border: none;
                margin: 1px;

                &:before {
                  content: '';
                  position: absolute;
                  background-color: #eee;
                  top: -1px;
                  left: -1px;
                  right: -1px;
                  bottom: -1px;
                  opacity: 0.6;

                }

                &:after {
                  content: '';
                  position: absolute;
                  border: 3px dashed #cfcfcf;
                  top: -1px;
                  left: -1px;
                  right: -1px;
                  bottom: -1px;
                }
              }
            }
          }
          .num-value {
            display: flex;
            font-size: 0;

            span {
              display: block;
              border: 1px solid #e8e8e8;
              text-align: center;
              min-width: 28px;
              width: 28px;
              height: 28px;
              line-height: 28px;
              font-size: 12px;

              &.store {
                width: auto;
                border-color: #ffffff;
                margin-left: 10px;
              }
            }

            input {
              display: block;
              border: none;
              height: 100%;
              width: 100%;
              text-align: center;
              outline: none;
            }

            .none-border {
              width: 30px;
              border:1px solid #e8e8e8;
              border-left: none;
              border-right: none;
            }
          }

        }

        .button {
          height: 50px;
          line-height: 50px;
          text-align: center;
          position: absolute;
          bottom: 0;
          left: 0;
          right: 0;
          border-radius: 0;
          background: @globalColor;
          &.disabled {
            background: #C2C2C2;
          }
        }
      }
    }
  }


  .cart-box{
    .cart-mask{
      position: fixed;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
      z-index: 200;
      background-color: rgba(0,0,0,.4);
    }
    .cart-dialog{

      position: fixed;
      z-index: 500;
      width: 85%;
      top: 50%;
      left: 50%;
      -webkit-transform: translate(-50%,-50%);
      transform: translate(-50%,-50%);
      background-color: #fafafc;
      text-align: center;
      border-radius: 5px;
      overflow: hidden;

      .title{
        padding: 20px 0;
        font-size: 15px;
      }
      .buttons{
        display: flex;
        padding: 20px 8px;
        font-size: 15px;
        word-wrap: break-word;
        word-break: break-all;

        .button{
          display: block;
          background: @globalColor;
          color: #fff;
          padding: 10px;
          margin: 0 8px;
          flex: 1;
          width: 0;
          text-align: center;
          border-radius:3px;

          &.agin{
            background-color: #FFFFFF;
            color: @globalColor;
            border: 1px solid @globalColor;
          }
        }
      }
    }
  }


  //弹出分享部分
  .share-box {
    background: #CDCDD1;
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 0;
    z-index: 50;
    transition:all .3s linear;
    .shaer-item {
      height: 50px;
      line-height: 50px;
      text-align: center;
      font-size: 18px;
      color: #2E2D2D;
      background: #ffffff;
      border-radius: 0;
      &:after {
        border: none;
      }
      &.clear {
        margin-top: 5px;
        color: #9B9B9B;
      }
    }


    &.cur{
      height: 155px;

    }
  }

  //选择优惠券以及促销活动部分
  .popup-box {
    background: #F7F7F7;
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 0;
    z-index: 50;


    transition:all .3s linear;


    &.cur{
      height: 60%;
    }

    .popup {
      height: 100%;
      box-sizing: border-box;

      .popup-top {
        padding: 0 15px;

        background: #e9e9e9;
        text-align: center;
        overflow: visible;

        .title {
          position: relative;
          color: #4A4A4A;
          overflow: visible;
          font-size: 14px;
          padding: 10px 0;

          .close {
            position: absolute;
            right: -10px;
            top: 0px;
            padding: 10px;
          }
        }
      }
      .popup-bottom {
        padding: 0 15px;
        height: 100%;
        overflow: auto;
        box-sizing: border-box;

        //优惠券
        &.coupon {
          .title{
            font-size: 14px;
            color: #000;
            padding-top: 8px;
          }
          .coupon-box {
            margin-bottom: 50px;
            .coupon-item {
              margin-bottom: 10px;
              &:first-child {
                margin-top: 10px;
              }
              .coupon {
                display: flex;

                &.shasow {
                  box-shadow: 0px 7px 10px 0px rgba(6, 0, 0, 0.2);
                }

                .coupon-left {
                  width: 110px;
                  height: 80px;
                  color: #ffffff;
                  background-size: cover;
                  background: @globalColor;
                  position: relative;

                  .text-wrap {
                    display: flex;
                    flex-direction: column;
                    justify-content: center;
                    align-items: center;
                    height: 100%;
                    font-size: 12px;
                    .text-box {
                      text-align: center;
                      width: 100%;
                      .text{
                        display: block;
                        padding: 0 10px;
                        overflow: hidden;
                        white-space: nowrap;
                        text-overflow: ellipsis;
                        font-size: 20px;
                        font-weight: 600;
                        &.label{
                          font-size: 12px;
                          font-weight: 100;
                        }
                        .money{
                          font-size: 14px;
                          font-weight: 100;
                        }
                      }

                      .money-num {
                        font-size: 25px;
                        font-weight: bold;
                      }
                    }
                  }
                  .dot-wrap {
                    position: absolute;
                    top: 0px;
                    margin-top: 5px;
                    .dot-item {
                      width: 5px;
                      height: 5px;
                      background: #F7F7F7;
                      border-radius: 50%;
                      margin: 4px 0 9px -1px;

                      &:last-child {
                        margin-top: 10px;
                      }
                    }
                  }
                }
                .coupon-right {
                  flex: 1;
                  background: #fff;
                  padding: 0px 15px;
                  font-size: 12px;
                  overflow: hidden;

                  .top {
                    font-size: 12px;
                    display: -webkit-box;
                    color: #333333;
                    height: 40px;
                    line-height: 20px;
                    padding-top: 8px;
                    box-sizing: border-box;
                    text-overflow: ellipsis;
                    -webkit-box-orient: vertical;
                    -webkit-line-clamp: 2;
                    .type {
                      color: #333333;
                      border: 1px solid #333333;
                      padding: 2px 5px;
                      border-radius: 3px;
                      line-height: 20px;
                      margin-right: 5px;
                    }
                  }

                  .bottom {
                    .bottom-use {
                      display: flex;
                      align-items: center;
                      justify-content: space-between;
                      font-size: 12px;
                      margin: 7px 0;
                      .tiem-box {
                        color: #9E9E9F;
                        flex: 1;
                        font-size: 9px;
                        overflow: hidden;
                        text-overflow: ellipsis;
                        white-space: nowrap;
                        margin-top: 5px;
                      }
                      .btn {
                        text-align: center;
                        border-radius: 3px;
                        padding: 3px 12px;
                      }
                      .use {
                        color: #fff;
                        border: 1px solid @globalColor;
                        background: @globalColor;
                      }
                      .already {
                        color: #9B9B9B;
                        background: #fff;
                        border: 1px solid #9B9B9B;
                      }
                    }
                  }
                }
              }
            }

          }
        }

        //促销
        &.discounts {
          height:100%;
          overflow: auto;
          box-sizing: border-box;
          .disconts-item {
            display: flex;
            align-items: baseline;
            padding: 10px 5px;
            &:last-child:before {
              display: none;
            }

            &:last-child {
              margin-bottom: 0;
            }
            .discounts-tags-title {
              color: @globalColor;
              border: 1px solid @globalColor;
              border-radius: 3px;
              padding: 0 5px;
              margin-right: 10px;
            }
            .tags-item{
              flex: 1;
            }
          }
        }
      }

    }
  }


  //弹出分享部分
  .share-box {
    background: #CDCDD1;
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 0;
    z-index: 50;
    transition:all .3s linear;
    .shaer-item {
      height: 50px;
      line-height: 50px;
      text-align: center;
      font-size: 18px;
      color: #2E2D2D;
      background: #ffffff;
      border-radius: 0;
      &:after {
        border: none;
      }
      &.clear {
        margin-top: 5px;
        color: #9B9B9B;
      }
    }


    &.cur{
      height: 155px;

    }
  }
}


